package com.iterator.mapper.web.systemManager;


import com.iterator.bean.wechat.dhy.WxUserLoginVO;

import com.iterator.bean.web.wy.admin.Admin;
import com.iterator.bean.web.wy.admin.AdminExample;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface AdminMapper {
    long countByExample(AdminExample example);

    int deleteByExample(AdminExample example);

    int deleteByPrimaryKey(Integer id);

    int insert(Admin record);

    int insertSelective(Admin record);

    List<Admin> selectByExample(AdminExample example);

    Admin selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("record") Admin record, @Param("example") AdminExample example);

    int updateByExample(@Param("record") Admin record, @Param("example") AdminExample example);

    int updateByPrimaryKeySelective(Admin record);

    int updateByPrimaryKey(Admin record);

    int selectMaxId();


    List<Admin> selectAllByUsername(@Param("username") String username);

    List<String> selectPasswordByUsername(String username);

    //查询user表里的信息
    List<String> selectUserPasswordByUsername(@Param("username") String username);

    //查询user表里的信息
    int updateUserLoginInfo(@Param("username") String username, @Param("host") String host);

    //查询user表里的信息
    WxUserLoginVO selectLoginInfoByUsername(String username);

    //查询权限表permission
    List<String> selectPermissionByroleId(List<Integer> roles);
    //查询权限角色表role
    List<String> selectRolesByroleId(List<Integer> roles);
}